In multi-threaded and/or multicore processors, a data structure may be shared between multiple threads and/or processor cores to allow multitasking on a common set of data while maintaining the consistency of the data. Such a data structure is referred to as a shared (or concurrent) data structure. A lock mechanism may be used to limit access to particular data element(s) of a shared data structure referenced by a section of program code when the section of code is being performed. Lock mechanisms may create a bottleneck that adversely affects overall system throughput and may result in deadlock. While fine-grained sections can be constructed at the programming level to alleviate this bottleneck by allowing different portions of a data structure to be locked independently, such construction involves significant programming time and effort.